package cn.itcast.dewu.pojo;

import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.Date;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import lombok.Data;
import lombok.experimental.Accessors;

/**
 *
 * @TableName tb_blog
 */
@TableName(value ="tb_blog")
@Data
@Accessors(chain = true)
public class Blog implements Serializable {
    /**
     * 主键
     */
    @TableId(type = IdType.INPUT)
    @JsonSerialize(using = ToStringSerializer.class)

    private Long id;

    /**
     *  商品id
     */
    @JsonSerialize(using = ToStringSerializer.class)

    private Long goodsId;

    /**
     * 用户id
     */
    @JsonSerialize(using = ToStringSerializer.class)

    private Long userId;

    /**
     * 标题
     */
    private String title;

    /**
     * 买家秀的照片，最多9张，多张以","隔开
     */
    private String images;

    /**
     * 买家秀的的文字描述
     */
    private String content;

    /**
     * 点赞数量
     */
    private Integer liked;

    /**
     * 评论数量
     */
    private Integer comments;

    /**
     * 创建时间
     */
    private LocalDateTime createTime;

    /**
     * 更新时间
     */
    private LocalDateTime updateTime;

    /**
     * 用户图标
     */
    @TableField(exist = false)
    private String icon;
    /**
     * 用户姓名
     */
    @TableField(exist = false)
    private String name;
    /**
     * 是否点赞过了
     */
    @TableField(exist = false)
    private Boolean isLike;
    /*
    * 商品图标
    * */
    @TableField(exist = false)
    private String goodsIcon;
    /*
    * 商品的名字
    *
    * */
    @TableField(exist = false)
    private String goodsName;
    /*
     *
     * 投放的钱数*/
    private Long isMoney;
    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}